package hypeerweb;

import java.util.Iterator;
import java.util.LinkedList;

public class DeleteConnections extends ModifyConnections {

	@Override
	public Iterator<NodeInterface> iterator(NodeInterface node) {
		LinkedList<NodeInterface> list = new LinkedList<NodeInterface>();
		
		list.addAll(node.getNeighbors());
		list.addAll(node.getDownPointers());
		//list.addAll(node.getUpPointers());
		list.add(node.getFold());
		//list.add(node.getSurrogateFold());
		list.add(node.getInverseSurrogateFold());
		
		
		return list.iterator();
	}

	@Override
	public void changeConnection(NodeInterface toBeChanged, Node node) {
		toBeChanged.DeleteMe(node);
	}

}
